﻿/*
 * Rss Image
 * 
 * See http://cyber.law.harvard.edu/rss/rss.html
 * 
 */

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;

namespace SNSpirit.Domain.Rss
{
    [Serializable]
    [XmlRoot(ElementName = "rssImage", Namespace = DomainUtillity.Namespace)]
    public class RssImage : DomainEntity
    {
        public const int MaxWidth = 144;
        public const int DefaultWidth = 88;
        public const int MaxHeight = 400;
        public const int DefaultHeight = 31;

        public RssImage()
        {
            this.Width = DefaultWidth;
            this.Height = DefaultHeight;
        }
        /// <summary>
        /// 
        /// </summary>
        [XmlAttribute(AttributeName = "uri", Namespace = DomainUtillity.Namespace)]
        public Uri Uri { get; set; }
        /// <summary>
        /// 
        /// </summary>
        [XmlAttribute(AttributeName = "title", Namespace = DomainUtillity.Namespace)]
        public string Title { get; set; }
        /// <summary>
        /// 
        /// </summary>
        [XmlAttribute(AttributeName = "link", Namespace = DomainUtillity.Namespace)]
        public Uri Link { get; set; }
        /// <summary>
        /// 
        /// </summary>
        [XmlAttribute(AttributeName = "width", Namespace = DomainUtillity.Namespace)]
        public int Width { get; set; }
        /// <summary>
        /// 
        /// </summary>
        [XmlAttribute(AttributeName = "height", Namespace = DomainUtillity.Namespace)]
        public int Height { get; set; }
        /// <summary>
        /// 
        /// </summary>
        [XmlAttribute(AttributeName = "description", Namespace = DomainUtillity.Namespace)]
        public string Descripton { get; set; }
    }
}
